package cn.elite.dao;

import cn.elite.pojo.User;

import java.util.List;

/**
 * @Author: ZLY
 * @Date: 2020/10/6 18:40
 * @Description:
 */
public interface IUserDao {
    /**
     * 查询所有
     * @return
     * @throws Exception
     */
    List<User> findAll() throws Exception;

    /**
     * 查询一条
     * @param user
     * @return
     * @throws Exception
     */
    User findByCondition(User user) throws Exception;

    /**
     * 增加
     * @param user
     * @return
     * @throws Exception
     */
    int addUser(User user) throws Exception;
    /**
     * 增加
     * @param user
     * @return
     * @throws Exception
     */
    int updateUser(User user) throws Exception;
    /**
     * 增加
     * @param id
     * @return
     * @throws Exception
     */
    int deleteUser(Integer id) throws Exception;
}
